package com.mh.dao;

import java.util.Date;
import java.util.List;
import java.util.Set;

import org.skyway.spring.util.dao.JpaDao;
import org.springframework.dao.DataAccessException;

import com.mh.domain.Customer;
import com.mh.domain.Invoice;
import com.mh.domain.Item;

/**
 * DAO to manage Invoice entities.
 * 
 */
public interface InvoiceDAO extends JpaDao<Invoice> {

	/**
	 * JPQL Query - findInvoiceByDocument
	 *
	 */
	public Set<Invoice> findInvoiceByDocument(String document) throws DataAccessException;

	/**
	 * JPQL Query - findInvoiceByDocument
	 *
	 */
	public Set<Invoice> findInvoiceByDocument(String document, int startResult, int maxRows) throws DataAccessException;

	/**
	 * JPQL Query - findAllInvoices
	 *
	 */
	public Set<Invoice> findAllInvoices() throws DataAccessException;

	/**
	 * JPQL Query - findAllInvoices
	 *
	 */
	public Set<Invoice> findAllInvoices(int startResult, int maxRows) throws DataAccessException;

	/**
	 * JPQL Query - findInvoiceByDocumentContaining
	 *
	 */
	public Set<Invoice> findInvoiceByDocumentContaining(String document_1) throws DataAccessException;

	/**
	 * JPQL Query - findInvoiceByDocumentContaining
	 *
	 */
	public Set<Invoice> findInvoiceByDocumentContaining(String document_1, int startResult, int maxRows) throws DataAccessException;

	/**
	 * JPQL Query - findInvoiceByModifiedOn
	 *
	 */
	public Set<Invoice> findInvoiceByModifiedOn(java.util.Date modifiedOn) throws DataAccessException;

	/**
	 * JPQL Query - findInvoiceByModifiedOn
	 *
	 */
	public Set<Invoice> findInvoiceByModifiedOn(Date modifiedOn, int startResult, int maxRows) throws DataAccessException;

	/**
	 * JPQL Query - findInvoiceByCreatedBy
	 *
	 */
	public Set<Invoice> findInvoiceByCreatedBy(String createdBy) throws DataAccessException;

	/**
	 * JPQL Query - findInvoiceByCreatedBy
	 *
	 */
	public Set<Invoice> findInvoiceByCreatedBy(String createdBy, int startResult, int maxRows) throws DataAccessException;

	/**
	 * JPQL Query - findInvoiceByPrimaryKey
	 *
	 */
	public Invoice findInvoiceByPrimaryKey(Integer id) throws DataAccessException;

	/**
	 * JPQL Query - findInvoiceByPrimaryKey
	 *
	 */
	public Invoice findInvoiceByPrimaryKey(Integer id, int startResult, int maxRows) throws DataAccessException;

	/**
	 * JPQL Query - findInvoiceById
	 *
	 */
	public Invoice findInvoiceById(Integer id_1) throws DataAccessException;

	/**
	 * JPQL Query - findInvoiceById
	 *
	 */
	public Invoice findInvoiceById(Integer id_1, int startResult, int maxRows) throws DataAccessException;

	/**
	 * JPQL Query - findInvoiceByTotal
	 *
	 */
	public Set<Invoice> findInvoiceByTotal(java.lang.Double total) throws DataAccessException;

	/**
	 * JPQL Query - findInvoiceByTotal
	 *
	 */
	public Set<Invoice> findInvoiceByTotal(Double total, int startResult, int maxRows) throws DataAccessException;

	/**
	 * JPQL Query - findInvoiceByCreatedByContaining
	 *
	 */
	public Set<Invoice> findInvoiceByCreatedByContaining(String createdBy_1) throws DataAccessException;

	/**
	 * JPQL Query - findInvoiceByCreatedByContaining
	 *
	 */
	public Set<Invoice> findInvoiceByCreatedByContaining(String createdBy_1, int startResult, int maxRows) throws DataAccessException;

	/**
	 * JPQL Query - findInvoiceByCreatedOn
	 *
	 */
	public Set<Invoice> findInvoiceByCreatedOn(java.util.Date createdOn) throws DataAccessException;

	/**
	 * JPQL Query - findInvoiceByCreatedOn
	 *
	 */
	public Set<Invoice> findInvoiceByCreatedOn(Date createdOn, int startResult, int maxRows) throws DataAccessException;

	/**
	 * JPQL Query - findInvoiceByModifiedByContaining
	 *
	 */
	public Set<Invoice> findInvoiceByModifiedByContaining(String modifiedBy) throws DataAccessException;

	/**
	 * JPQL Query - findInvoiceByModifiedByContaining
	 *
	 */
	public Set<Invoice> findInvoiceByModifiedByContaining(String modifiedBy, int startResult, int maxRows) throws DataAccessException;

	/**
	 * JPQL Query - findInvoiceByModifiedBy
	 *
	 */
	public Set<Invoice> findInvoiceByModifiedBy(String modifiedBy_1) throws DataAccessException;

	/**
	 * JPQL Query - findInvoiceByModifiedBy
	 *
	 */
	public Set<Invoice> findInvoiceByModifiedBy(String modifiedBy_1, int startResult, int maxRows) throws DataAccessException;

	
	public List<Invoice> findAllInvoices(Invoice invoice, int page, int maxRows);
	
	public List<Invoice> findAllInvoicesForCustomer(Customer customer, int startResult, int maxRows);
}